package DataView;

import java.util.Vector;

import Store.Attribute;
import Store.Operation;

public class ClassInfo extends CDElementInfo 
{
	public Vector<Operation> list_Operation=null;
	public Vector<Attribute> list_Attribute=null;
	
	public void setInfo(String name, Vector<Operation> operazioni, Vector<Attribute> attributi) 
	{
		super.setInfo(name);
		list_Attribute=attributi;
		list_Operation=operazioni;
	}
	
	public ClassInfo clone()
	{
		ClassInfo clone = new ClassInfo();
		Vector<Operation> list_Operation_clone = new Vector<Operation>();
		Vector<Attribute> list_Attribute_clone = new Vector<Attribute>();
		for(Operation o : list_Operation)
			list_Operation_clone.add(o.clone());
		for(Attribute o : list_Attribute)
			list_Attribute_clone.add(o.clone());
		
		clone.setInfo(getName(), list_Operation_clone, list_Attribute_clone);
		return clone;
	}
}